<!DOCTYPE html>
<!--suppress ALL-->
<html lang="en" xmlns:v-on="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org"
      xmlns:sec="http://www.thymeleaf.org/thymeleaf-extras-springsecurity3">
<head>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <link rel="stylesheet" type="text/css" th:href="@{/static/h-ui/css/H-ui.min.css}"/>
    <link rel="stylesheet" type="text/css" th:href="@{/static/h-ui.admin/css/H-ui.admin.css}"/>
    <link rel="stylesheet" type="text/css" th:href="@{/static/lib/Hui-iconfont/1.0.8/iconfont.css}"/>
    <link rel="stylesheet" type="text/css" th:href="@{/static/h-ui.admin/skin/default/skin.css}" id="skin"/>
    <link rel="stylesheet" type="text/css" th:href="@{/static/h-ui.admin/css/style.css}"/>
    <link rel="stylesheet" type="text/css" th:href="@{/static/lib/laypage/1.2/skin/laypage.css}">
    <script type="text/javascript" th:src="@{/static/lib/jquery/1.9.1/jquery.min.js}"></script>
    <script type="text/javascript" th:src="@{/static/lib/layer/2.4/layer.js}"></script>
    <script type="text/javascript" th:src="@{/static/h-ui/js/H-ui.min.js}"></script>
    <script type="text/javascript" th:src="@{/static/h-ui.admin/js/H-ui.admin.js}"></script>
    <script type="text/javascript" th:src="@{/static/lib/My97DatePicker/4.8/WdatePicker.js}"></script>
    <script type="text/javascript" th:src="@{/static/lib/datatables/1.10.0/jquery.dataTables.min.js}"></script>
    <script th:src="@{/static/lib/vue.min.js}"></script>
    <script th:src="@{/static/js/laypage/laypage.js}"></script>
<!--  引入js  -->
    <script type="text/javascript" th:src="@{https://cdn.goeasy.io/goeasy-1.0.3.js}"></script>
</head>
<body>
<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span> 会员管理 <span class="c-gray en">&gt;</span> 会员列表 <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
<div class="page-container" style="text-align: center">
    请填写发送给普通用户的通知：<br/>
    <textarea  id="content" style="width: 1000px;height: 600px"></textarea>
    <br/>
    <input type="button" value="发布" id="fabuButten"
           style=" border: 0px solid midnightblue;
        width: 100px;
        height: 30px;
        background-color: dodgerblue;
        color: white;">
</div>
</body>
<script type="text/javascript">
    var goEasy = new GoEasy({
        host:'hangzhou.goeasy.io',//应用所在的区域地址，杭州：hangzhou.goeasy.io，新加坡：singapore.goeasy.io
        appkey: "BC-7aa730f238184e2eb8e4dcbd087e10e0",//替换为您的应用appkey
        forceTLS:false, //如果需要使用HTTPS/WSS，请设置为true，默认为false
        onConnected: function() {
            console.log('连接成功！')
        },
        onDisconnected: function() {
            console.log('连接断开！')
        },
        onConnectFailed: function(error) {
            console.log('连接失败或错误！')
        }
    });
    //订阅，接受消息
    // goEasy.subscribe({
    //     channel: "my_channel",//替换为您自己的channel
    //     onMessage: function (message) {
    //         console.log("Channel:" + message.channel + " content:" + message.content);
    //     }
    // });
    //发送消息
    // goEasy.publish({
    //     channel: "my_channel", //替换为您自己的channel
    //     message: "Hello, GoEasy!" //替换为您想要发送的消息内容
    // });




    $("#fabuButten").click(function () {
        //alert("准备发送");
        var msg=$("#content").val();
        goEasy.publish({
            channel: "Puser_channel", //替换为您自己的channel
            message: msg //替换为您想要发送的消息内容
        });
        $("#content").val("");
        alert("发送成功！");
    });



</script>

</html>